package com.wsq.coroutine.retrofit

import okhttp3.OkHttpClient
import retrofit2.Retrofit
import retrofit2.converter.gson.GsonConverterFactory

/**
 *
 *Date:2022/5/25
 *Time:7:41
 *author:wushengqi
 *
 * 懒汉模式
 */
object HttpClient {
    val retrofit:Retrofit by lazy {
        val client = OkHttpClient.Builder()
        Retrofit.Builder()
            .addConverterFactory(GsonConverterFactory.create())
            .baseUrl("http://47.101.190.251:5678/")
            .client(client.build())
            .build()
    }

}